<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:aop="http://www.springframework.org/schema/aop" xmlns:context="http://www.springframework.org/schema/context" xmlns:jee="http://www.springframework.org/schema/jee" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.2.xsd         http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd         http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.2.xsd         http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.2.xsd         http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.2.xsd">
    <!--
        This will automatically locate any and all property files you have
        within your classpath, provided they fall under the META-INF/spring
        directory. The located property files are parsed and their values can
        then be used within application context files in the form of
        ${propertyKey}.
    -->
    <context:property-placeholder location="classpath*:META-INF/spring/*.properties"/>
    <!--
        Turn on AspectJ @Configurable support. As a result, any time you
        instantiate an object, Spring will attempt to perform dependency
        injection on that object. This occurs for instantiation via the "new"
        keyword, as well as via reflection. This is possible because AspectJ
        is used to "weave" Roo-based applications at compile time. In effect
        this feature allows dependency injection of any object at all in your
        system, which is a very useful feature (without @Configurable you'd
        only be able to dependency inject objects acquired from Spring or
        subsequently presented to a specific Spring dependency injection
        method). Roo applications use this useful feature in a number of
        areas, such as @PersistenceContext injection into entities.
    -->
    <context:spring-configured/>
    <!--
        This declaration will cause Spring to locate every @Component,
        @Repository and @Service in your application. In practical terms this
        allows you to write a POJO and then simply annotate the new POJO as an
        @Service and Spring will automatically detect, instantiate and
        dependency inject your service at startup time. Importantly, you can
        then also have your new service injected into any other class that
        requires it simply by declaring a field for your service inside the
        relying class and Spring will inject it. Note that two exclude filters
        are declared. The first ensures that Spring doesn't spend time
        introspecting Roo-specific ITD aspects. The second ensures Roo doesn't
        instantiate your @Controller classes, as these should be instantiated
        by a web tier application context. Refer to web.xml for more details
        about the web tier application context setup services.
        
        Furthermore, this turns on @Autowired, @PostConstruct etc support. These 
        annotations allow you to use common Spring and Java Enterprise Edition 
        annotations in your classes without needing to do any special configuration. 
        The most commonly used annotation is @Autowired, which instructs Spring to
        dependency inject an object into your class.
    -->
    <context:component-scan base-package="com.qiyadeng.wechat">
        <context:exclude-filter expression=".*_Roo_.*" type="regex"/>
        <context:exclude-filter expression="org.springframework.stereotype.Controller" type="annotation"/>
    </context:component-scan>
    <bean class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close" id="dataSource">
        <property name="driverClassName" value="${database.driverClassName}"/>
        <property name="url" value="${database.url}"/>
        <property name="username" value="${database.username}"/>
        <property name="password" value="${database.password}"/>
        <property name="testOnBorrow" value="true"/>
        <property name="testOnReturn" value="true"/>
        <property name="testWhileIdle" value="true"/>
        <property name="timeBetweenEvictionRunsMillis" value="1800000"/>
        <property name="numTestsPerEvictionRun" value="3"/>
        <property name="minEvictableIdleTimeMillis" value="1800000"/>
        <property name="validationQuery" value="SELECT 1"/>
    </bean>
    <bean class="org.springframework.orm.jpa.JpaTransactionManager" id="transactionManager">
        <property name="entityManagerFactory" ref="entityManagerFactory"/>
    </bean>
    <tx:annotation-driven mode="aspectj" transaction-manager="transactionManager"/>
    <bean class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean" id="entityManagerFactory">
        <property name="persistenceUnitName" value="persistenceUnit"/>
        <property name="dataSource" ref="dataSource"/>
    </bean>

   	<bean class="com.qiyadeng.company.biz.MmtConstant">
   		<property name="serviceAddress" value="http://webservice.mymyti.com/mmtwebservice/services/MmtInterface"></property>
   		<property name="merMo" value="2026"></property>
   		<property name="termMermo" value="20269997"></property>
   		<property name="loginid" value="weixin"></property>
   		<property name="loginpassword" value="!q2az9"></property>
   		<property name="ticketType" value="20260012"></property>
   		<property name="smsAddress" value="http://webservice.mymyti.com/mmtwebservice/services/MmtInterface"></property>
   		<property name="smsLogin" value="weixin"></property>
   		<property name="smsPasswd" value="!q2az9"></property>
   		<property name="smsMerno" value="2026"></property>
   		<property name="smsTermMerno" value="20269997"></property>
   		<property name="superMerno" value="2026"></property>
   		<property name="superLogin" value="weixin"></property>
   		<property name="superPassword" value="!q2az9"></property>
   	</bean>
   	<bean class="com.qiyadeng.wechat.config.WeChatConstant">
   		<property name="prodCountInCom" value="8"></property>
   		<property name="defaultCity" value="上海"></property>
   		<property name="surveyAddress" value="http://112.124.6.233:81/limesurvey/index.php/survey/index/sid/179129/"></property>
   		<property name="fromUserName" value="iceason0001"></property>
   		<property name="basePicWebsite" value="http://demo.mymyti.com/WeChatDemo"></property>
   		<property name="smsCheckCode" value="您的验证码是："></property>
   		<property name="followMessage" value="感谢您关注爱茜茜里官方微信，我们正在努力完善微信功能。&#x0A;感谢您关注爱茜茜里官方微信，我们正在努力完善微信功能。&#x0A;请输入问题序列号活直接向我提问，如“蛋糕”“积分”等&#x0A;【1】用户注册&#x0A;【2】会员卡绑定&#x0A;【3】积分查询&#x0A;【4】会员卡修改密码&#x0A;【5】问卷有礼&#x0A;【6】产品明细&#x0A;【7】当月促销活动&#x0A;【8】公司介绍&#x0A;【9】门店查询（或直接发送地理位置查找附近门店） 【10】新品推荐"></property>
   		<property name="productMessage" value="【6】产品明细\n【10】新品推荐\n【11】冰淇淋单球\n【12】大蛋糕冰淇淋\n【13】茶饮\n【14】咖啡\n【15】礼券礼卡"></property>
   		<property name="companyIntro" value="爱茜茜里是来自意大利的手工冰激淋品牌，近些年进军中国市场并获得许多年轻顾客的喜爱。"></property>
   		<property name="productHint" value="请直接输入关键字，如冰淇淋、蛋糕等进行搜索"></property>
   		<property name="storeHint" value="请直接发送地理位置或是输入路名查找附近门店"></property>
   		<property name="scoreHint" value="您的积分为："></property>
   		<property name="modifyCardPassword" value="修改卡密码请点右边链接,"></property>
   		<property name="givenCouponMsg" value="问券送好礼：任意三球杯第二杯半价，券号：{0}该电子券有效期自发放日起三个月内有效【爱茜茜里】"></property>
   		<property name="regMsg" value="微信注册送好礼：任意热饮第二杯半价，券号：{0}该电子券有效期自发放日起三个月内有效【爱茜茜里】"></property>
   	
   	</bean>
</beans>
